Example 7 - Using the AddTaskUsingDuration method

 

This example starts Milestones Professional, creates a new file, and places several symbols on the schedule using the AddTaskUsingDuration call.  It prints the schedule and then closes it.

 

 

Public Sub Example7()

Set objMilestones = CreateObject("Milestones")

With objMilestones

  .Activate

  .AddTaskUsingDuration 1, "7/12/2022", 2, 5, 2, 2, 65, "Day", 12, 0, "Create Using Days"

  .AddTaskUsingDuration2, "9/11/2022", 2, 5, 2, 2, 65, "Day", 12, 0, "Create Using Days"

  .AddTaskUsingDuration 3, "7/12/2022", 2, 5, 2, 2, 480, "Hour", 12, 0, "Create Using Hours"

  .AddTaskUsingDuration4, "9/11/2022", 2, 5, 2, 2, 480, "Hour", 12, 0, "Create Using Hours"

  .AddTaskUsingDuration5, "2/1/2022", 2, 5, 2, 2, 4800, "Minute", 12, 0, "Create Using Minutes"

  .Refresh

  .Print

  .Close

 

End With

Exit Sub

End Sub

 

 

 

        

 

 

 

 

Related Topics

  1. AddTaskUsingDuration
  2. Print

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

To effectively program with this interface, it's important to learn all about Milestones Professional.  Learn about Milestones.

Milestones Professional 2025 Automation Methods and Properties.  © Copyright 2000-2025, KIDASA Software, Inc. All rights reserved.